package cn.wolfcode.crm.web.controller;

import cn.wolfcode.crm.query.TransferQueryObject;
import cn.wolfcode.crm.service.ITransferHistoryService;
import cn.wolfcode.crm.util.PageResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("transferHistory")
public class TransferHistoryController {
    @Autowired
    private ITransferHistoryService transferHistoryService;

    @RequestMapping("view")
    public String view() {
        return "transferHistory/list";
    }

    @RequestMapping("list")
    @ResponseBody
    public PageResult list(TransferQueryObject qo) {
        PageResult result = transferHistoryService.query(qo);
        return result;
    }
}
